package com.iscale.model.entity;

import com.baomidou.mybatisplus.activerecord.Model;
import java.util.Date;

import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.enums.IdType;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

import java.io.Serializable;


/**
 * <p>
 * 业务类型
 * </p>
 *
 * @author Andychen
 * @since 2017-03-10
 */
@SuppressWarnings("serial")
@JsonIgnoreProperties(ignoreUnknown = true)
@TableName("sys_business_type")
public class SysBusinessType extends Model<SysBusinessType> {

    private static final long serialVersionUID = 1L;

    /**
     * ID
     */
	@TableId(value = "id", type = IdType.ID_WORKER)//分布式全局唯一 IdType.ID_WORKER
	private Long id;
    /**
     * 业务代号
     */
	@TableField("serviceCode")
	private String serviceCode;
    /**
     * 业务名称
     */
	private String name;
	/**
	 * 描述
	 */
	private String description;
	@TableField("createTime")
	private Date createTime;
	@TableField("updateTime")
	private Date updateTime;
	@TableField("createUser")
	private String createUser;
	@TableField("updateUser")
	private String updateUser;
    /**
     * 业务状态 0-正常 1-取消
     */
	private Integer status;
    /**
     * 允许删除 0-不允许  1-允许
     */
	@TableField("isFinal")
	private Integer isFinal;
    /**
     * 排序
     */
	private Long rank;

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getServiceCode() {
		return serviceCode;
	}

	public void setServiceCode(String serviceCode) {
		this.serviceCode = serviceCode;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public Date getUpdateTime() {
		return updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	public String getCreateUser() {
		return createUser;
	}

	public void setCreateUser(String createUser) {
		this.createUser = createUser;
	}

	public String getUpdateUser() {
		return updateUser;
	}

	public void setUpdateUser(String updateUser) {
		this.updateUser = updateUser;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public Integer getIsFinal() {
		return isFinal;
	}

	public void setIsFinal(Integer isFinal) {
		this.isFinal = isFinal;
	}

	public Long getRank() {
		return rank;
	}

	public void setRank(Long rank) {
		this.rank = rank;
	}

	@Override
	protected Serializable pkVal() {
		return this.id;
	}

	public SysBusinessType(){}

	public SysBusinessType(String serviceCode, String name, String description, String createUser, Integer isFinal,Integer status) {
		this.serviceCode = serviceCode;
		this.name = name;
		this.description = description;
		this.createUser = createUser;
		this.isFinal = isFinal;
		this.createTime = new Date();
		this.status = status;
	}

	public SysBusinessType(Long id, String serviceCode) {
		this.id = id;
		this.serviceCode = serviceCode;
	}
}
